import seqPreprocessor from 'svelte-sequential-preprocessor';
import { preprocessThrelte } from '@threlte/preprocess';

import { mdsvex } from 'mdsvex';
import mdsvexConfig from './mdsvex.config.js';
// import autoImport from 'vite-plugin-autoimport';

import adapter from '@sveltejs/adapter-static';

import { vitePreprocess } from '@sveltejs/kit/vite';

/** @type {import('@sveltejs/kit').Config} */
const config = {
	// Consult https://github.com/sveltejs/svelte-preprocess
	// for more information about preprocessors
	extensions: ['.svelte', ...mdsvexConfig.extensions],
	preprocess: seqPreprocessor([
		vitePreprocess(),
		preprocessThrelte(),
		mdsvex(mdsvexConfig)
	]),

	kit: {
		adapter: adapter({
			pages: 'dist',
			assets: 'dist'
		})
	}
	// vitePlugin: {
	// 	experimental: {
	// 		inspector: true
	// 		// 	inspector: {
	// 		// 		// change shortcut
	// 		// 		toggleKeyCombo: 'meta-shift',
	// 		// 		// hold and release key to toggle inspector mode
	// 		// 		holdMode: true,
	// 		// 		// show or hide the inspector option
	// 		// 		showToggleButton: 'always',
	// 		// 		// inspector position
	// 		// 		toggleButtonPos: 'top-right',
	// 		// 	},
	// 	},
	// },
};

export default config;
